from django.contrib.auth.decorators import login_required
from django.views.decorators.cache import never_cache
from django.contrib.auth.views import logout
from django.core.files import base
from django.http import HttpResponse
from django.shortcuts import render_to_response, redirect, get_object_or_404
from django.template.context import RequestContext
import os
from django.template.loader import render_to_string
import random

def logoutuser(request):
    logout(request)
    return redirect('regoloweb.ui.views.index')

def __abs_filefield_path(filefield):
    return os.path.join(filefield.storage.location, filefield.name)

@login_required
@never_cache
def index(request):
    return render_to_response('webui/index.html', { }, RequestContext(request))
